package com.gxar.quick.ar.server.db.model;

import com.alibaba.fastjson2.annotation.JSONField;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.gxar.quick.ar.server.base.common.enums.ComboTypeEnum;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;

/**
 * 套餐实体
 *
 * @author linsy
 * @version 1.0
 * @created 2023/11/7 10:30
 */
@Entity
@Getter
@Setter
@NoArgsConstructor
@Table(name = "combo")
public class ComboEntity implements Serializable {

    /**
     * 套餐id
     */
    @Id
    private Long id;
    /**
     * 套餐名称
     */
    @Column(nullable = false)
    private String name;
    /**
     * 付费方式
     * {@link com.gxar.quick.ar.server.base.common.enums.ComboBillMethodEnum}
     */
    @Column(nullable = false)
    private Integer billMethod;
    /**
     * 计费项
     * {@link com.gxar.quick.ar.server.base.common.enums.ComboItemEnum}
     */
    @Column(nullable = false)
    private Integer item;
    /**
     * 套餐等级
     * {@link  com.gxar.quick.ar.server.base.common.enums.ComboGradeEnum}
     */
    @Column(nullable = false)
    private Integer grade;

    /**
     * 套餐类型：会员套餐
     * {@link com.gxar.quick.ar.server.base.common.enums.ComboTypeEnum}
     */
    @Column(nullable = false)
    private Integer type;
    /**
     * 套餐描述信息
     */
    private String description;
    /**
     * 计费项值
     */
    @Column(nullable = false)
    private Integer itemValue;
    /**
     * 计费项值的单位
     */
    @Column(nullable = false)
    private String itemValueUnit;
    /**
     * 套餐配置
     */
    @Column(nullable = false)
    private String config;
    /**
     * 币种
     */
    @Column(nullable = false)
    private String currency;
    /**
     * 原价
     */
    private BigDecimal oriPrice;
    /**
     * 套餐价格
     */
    @Column(nullable = false)
    private BigDecimal price;
    /**
     * 图标
     */
    @Column(nullable = false)
    private String icon;
    /**
     * 背景
     */
    @Column(nullable = false)
    private String background;
    /**
     * 创建时间
     */
    @Column(nullable = false)
    private Date createdAt;
    /**
     * 创建者
     */
    @Column(nullable = false)
    private String creator;
    /**
     * 更新时间
     */
    @Column(nullable = false)
    private Date updatedAt;
    /**
     * 更新者
     */
    private String operator;

    /**
     * 是否删除
     */
    private Boolean deleted;
}
